<?php $this->widget('application.components.RubricsTree', array(
  'service_type'=> $st_id,
  'rubric_id' => $rubric_id,
  'category_id' => $category_id
)); ?>
<section class="list_firms">
  <div class="top_category">
    <div class="pager_container">
			<?php
				$this->widget('CLinkPager', array(
					'htmlOptions' => array('class'=> ''),
					'pages' => $pages,
					'header' => '',
					'firstPageLabel' => '&laquo;',
					'prevPageLabel' => '&lsaquo;',
					'nextPageLabel' => '&rsaquo;',
					'lastPageLabel' => '&raquo;',
					'hiddenPageCssClass' => 'disabled',
					'selectedPageCssClass' => 'active'
				));
			?>      
    </div>
    <h2 class="name_menu_category"><?php echo $category['name'];?></h2>
  </div>
  <div class="breadcrumbs_category">
    <ol class="brdcrm_region">
      <li><a href="#">Главная</a></li>
      <li><a href="#"><?php echo Controller::getServiceType($st_id)?></a></li>
      <?php if (isset($rubric['name'])) : ?>
        <li><a href="#"><?php echo $rubric['name'];?></a></li>
      <?php endif; ?>      
      <?php if (isset($rubric['name'])) : ?>
        <li class="active"><a href="#"><?php echo $category['name'];?></a></li>
      <?php endif; ?>      
    </ol>
  </div>
  <div class="container_firms">
    <?php if (0 < count($firms)):?>
    <ul class="firms">
      <?php foreach($firms as $firm):?>
      <?php $firm_lnk = Yii::app()->createUrl('/firm', array('id'=>$firm->id, 'slug'=> $firm->slug)); ?>
      <?php // if ($firm->logo) $this->getFirmImgSrc($firm->logo, 'firms_img_logo'); ?>
						<li class="firm_item">
							<div class="top_content">
								<div class="left_content_info">
									<div class="top_name">
										<span><a href="<?php echo $firm_lnk; ?>"><?php echo GxHtml::encode($firm->title);?></a></span>
									</div>
									<div class="unwind">
										<span><?php echo GxHtml::truncate(GxHtml::smart_encode(strip_tags($firm->description)), 300, '...', false);?></span>
									</div>
									<div class="bread_crb"> 
										<ol class="region_item">
											<li><a href="#"><?php echo GxHtml::encode($firm->region);?></a></li>
											<li><a href="#"><?php echo GxHtml::encode($firm->city);?></a></li>
											<li class="active"><a href="#"><?php echo GxHtml::encode($firm->address);?></a></li>
										</ol>
									</div>
								</div>
								<div class="separate"></div>
								<div class="right_content_info"></div>
							</div>
							<div class="bottom_content">
								<div class="phone_section">
									<span><?php echo GxHtml::encode($firm->phone);?></span>
								</div>
								<div class="mail_section">
									<a>
										<span><?php echo GxHtml::encode($firm->email);?></span>
									</a>									
								</div>
								<div class="site_section">
									<a>
										<span>www.dsfsdfdf.com</span>
									</a>
								</div>
							</div>
						</li>      
      
      <?php endforeach; ?>
    </ul>
		<?php else: ?>
      <p><?php echo Yii::t('app', 'Записи не найдены'); ?></p>
    <?php endif; ?>    
  </div>  
</section>